// 电感系列
const InductanceStandards: any = {
  InstallationMethod: '安装方式',
  RatedDistanceSn: '额定距离 Sn',
  SafeDistanceSa: '确保距离 Sa',
  Dimension: '外形规格',
  OutputType: '输出方式',
  PowerSupplyVoltage: '电源电压',
  StandardTarget: '标准标靶',
  SwitchPointDeviation: '开关点偏移[%/Sr]',
  HysteresisRange: '迟滞范围[%/Sr]',
  RepeatError: '重复误差',
  LoadCurrent: '负荷电流',
  ResidualVoltage: '残留电压',
  LeakageCurrent: '漏电流',
  ProtectionCircuit: '保护回路',
  PowerIndicator: '电源指示',
  AmbientTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  SwitchingFrequency: '开关频率',
  ImpulseWithstandVoltage: '冲击耐压',
  InsulationResistance: '绝缘阻抗',
  VibrationResistance: '耐振动',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  WiringMethod: '接线方式'
}
const InductanceEssence = {
  InstallationMethod: '安装方式',
  RatedDistanceSn: '额定距离 Sn',
  SafeDistanceSa: '确保距离 Sa',
  Dimension: '外形规格',
  OutputMethod: '输出方式',
  PowerSupplyVoltage: '电源电压',
  StandardTarget: '标准标靶',
  SwitchPointDeviation: '开关点偏移[%/Sr]',
  HysteresisRange: '迟滞范围[%/Sr]',
  RepeatError: '重复误差',
  OutputCurrent: '输出电流',
  PressureDrop: '压降',
  LoadImpedance: '负载阻抗',
  AmbientTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  SwitchingFrequency: '开关频率',
  InsulationImpedance: '绝缘阻抗',
  VibrationResistance: '耐振动',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  ConnectionMethod: '接线方式'
}
const InductorAnalog = {
  InstallationMethod: '安装方式',
  RatedDistanceSn: '额定距离Sn',
  DetectionDistance: '检测距离',
  Dimension: '外形规格',
  OutputMethod: '输出方式',
  PowerSupplyVoltage: '电源电压',
  StandardTarget: '标准标靶',
  SwitchPointDeviation: '开关点偏移[%/Sr]',
  Linearity: '线性度',
  RepeatError: '重复误差',
  LoadCurrent: '负荷电流',
  ResidualVoltage: '残留电压',
  ConsumptionCurrent: '消耗电流',
  ProtectionCircuit: '保护回路',
  PowerIndicator: '电源指示',
  AmbientTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  SwitchingFrequency: '开关频率',
  ImpulseVoltage: '冲击耐压',
  InsulationImpedance: '绝缘阻抗',
  VibrationResistance: '耐振动',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  ConnectionMethod: '接线方式'
}

// 光电微偏
const PhotoelectricMicroBias = {
  DetectionDistance: '检测距离',
  StandardDetectionBody: '标准检测体',
  LaunchAngle: '发射角度',
  Indicators: '指示灯',
  SpotSize: '光斑大小',
  PowerSupplyVoltage: '电源电压',
  ConsumptionCurrent: '消耗电流',
  LoadCurrent: '负载电流',
  VoltageDrop: '压降',
  LightSourceType: '光源类型',
  ProtectionCircuit: '保护回路',
  ResponseTime: '响应时间',
  IndicatorLight:"指示灯",
  AmbientLightResistance:"抗环境光",
  OperatingTemperature: '工作温度',
  StorageTemperature: '存储温度',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  LensMaterial: '透镜',
  Weight: '重量',
  ConnectionMethod: '连接方式',
  Accessories: '附件'
}
const OptoelectronicMicroSquare = {
  DetectionMethod: '检测方式',
  RatedDistance: '额定距离 Sn',
  StandardDetectionBody: '标准检测体',
  LightSource: '光源',
  OutlineSpecification: '外形规格',
  OutputMethod: '输出方式',
  PowerSupplyVoltage: '电源电压',
  MinimumDetectionBody: '最小检测体',
  HysteresisRange: '迟滞范围[%/Sr]',
  RepeatError: '重复误差',
  LoadCurrent: '负荷电流',
  ResidualVoltage: '残留电压',
  ConsumptionCurrent: '消耗电流',
  ProtectionCircuit: '保护回路',
  ResponseTime: '响应时间',
  OutputIndication: '输出指示',
  OperatingTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  ImpulseWithstandVoltage: '冲击耐压',
  InsulationImpedance: '绝缘阻抗',
  VibrationResistance: '耐振动',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  WiringMethod: '接线方式'
}
const OptoelectronicSmallSquare = {
  DetectionMethod: '检测方式',
  DetectionDistance: '检测距离',
  OutputMode: '输出方式',
  DistanceAdjustment: '距离调节',
  OutputStatus: '输出状态',
  SpotSize: '光斑大小',
  OperatingVoltage: '工作电压',
  CurrentConsumption: '消耗电流',
  LoadCurrent: '负载电流',
  VoltageDrop: '压降',
  LightSourceType: '光源类型',
  ResponseTime: '响应时间',
  MinimumDetectionObject: '最小检测体',
  ProtectionCircuit: '保护回路',
  Indicators: '指示灯',
  AmbientLightResistance: '抗环境光',
  OperatingTemperature: '工作温度',
  StorageTemperature: '储存温度',
  HumidityRange: '湿度范围',
  ProtectionLevel: '防护等级',
  ComplianceStandard: '符合标准',
  ProductionStandard: '生产标准',
  Material: '材质',
  Weight: '重量'
}

// 电容系列
const CapacitanceStandard = {
  InstallationMethod: '安装方式',
  RatedDistanceSn: '额定距离 Sn',
  EnsuredDistanceSa: '确保距离 Sa',
  OutlineSpecification: '外形规格',
  OutputMode: '输出方式',
  PowerSupplyVoltage: '电源电压',
  StandardTarget: '标准标靶',
  SwitchingPointOffset: '开关点偏移[%/Sr]',
  HysteresisRange: '迟滞范围[%/Sr]',
  RepeatError: '重复误差',
  LoadCurrent: '负荷电流',
  ResidualVoltage: '残留电压',
  LeakageCurrent: '漏电流',
  ProtectionCircuit: '保护回路',
  OutputIndication: '输出指示',
  OperatingTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  SwitchingFrequency: '开关频率',
  HighVoltageResistance: '耐高压',
  InsulationImpedance: '绝缘阻抗',
  VibrationResistance: '耐振动',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  WiringMethod: '接线方式'
}
const CapacitorFrequency = {
  InstallationMethod: '安装方式',
  RatedDistance: '额定距离',
  AdjustmentDistance: '调节距离',
  AdjustmentMethod: '调节方式',
  OutlineSpecification: '外形规格',
  OutputMode: '输出方式',
  PowerSupplyVoltage: '电源电压',
  StandardTarget: '标准标靶',
  SwitchingPointOffset: '开关点偏移',
  HysteresisRange: '迟滞范围',
  RepeatError: '重复误差',
  LoadCurrent: '负荷电流',
  ResidualVoltage: '残留电压',
  ConsumptionCurrent: '消耗电流',
  ProtectionCircuit: '保护回路',
  OutputIndication: '输出指示',
  SwitchingFrequency: '开关频率',
  VibrationResistance: '耐振动',
  ImpactResistance: '耐冲击',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  WiringMethod: '接线方式'
}
const CapacitanceEnhancement = {
  InstallationMethod: '安装方式',
  RatedDistanceSn: '额定距离Sn',
  EnsureDistanceSa: '确保距离Sa',
  AdjustmentDistance: '调节距离',
  AdjustmentMethod: '调节方式',
  StandardDetectionObject: '标准检测物',
  PowerSupplyVoltage: '电源电压',
  LoadCurrent: '负载电流',
  ResidualVoltage: '残留电压',
  ConsumptionCurrent: '消耗电流',
  SwitchingPointOffset: '开关点偏移[%/Sn]',
  TemperatureOffset: '温度偏移[%/Sr]',
  HysteresisRange: '迟滞范围[%/Sr]',
  RepeatError: '重复误差[R]',
  ProtectionCircuit: '保护回路',
  IndicatorLight: '指示灯',
  SwitchingFrequency: '开关频率',
  AmbientTemperature: '环境温度',
  AmbientHumidity: '环境湿度',
  VibrationResistance: '耐振动',
  ImpactResistance: '耐冲击',
  WithstandVoltage: '耐高压',
  InsulationImpedance: '绝缘阻抗',
  OutlineSpecification: '外形规格',
  ProtectionLevel: '防护等级',
  ShellMaterial: '外壳材料',
  WiringMethod: '接线方式',
  Accessories: '附件'
}
// 激光
const LaserRanging = {
  InstallationDistance: "安装距离",  
  MeasurementRange: "测量高度范围",  
  Repeatability: "重复精度",  
  Linearity: "线性精度",  
  SamplingPeriod: "采样周期",  
  LaserWavelength: "激光波长",  
  CommunicationMethod: "通讯方式"  
}


export function ReturnSericesConfig(type: string, series: string) {
  if (!type || !series) {
    return {}
  }

  switch (type) {
    case '电容式传感器':
      switch (series) {
        case '标准功能系列':
          return CapacitanceStandard
        case '频率增强系列':
          return CapacitorFrequency
        case '增强远距离系列':
          return CapacitanceEnhancement
        default:
          return {}
      }
    case '电感式传感器':
      switch (series) {
        case '标准功能系列':
          return InductanceStandards
        case '本质安全系列':
          return InductanceEssence
        case '模拟量输出系列':
          return InductorAnalog
        default:
          return {}
      }
    case '光电式传感器':
      switch (series) {
        case '微扁形系列(PSV)':
          return PhotoelectricMicroBias
        case '微方形系列(PST/PSJ)':
          return OptoelectronicMicroSquare
        case '小方形系列(PSE)':
          return OptoelectronicSmallSquare
        default:
          return {}
      }
    case '测量传感器':
      switch (series) {
        case '高精度激光位移传感器':
          return LaserRanging
        case '激光位移传感器':
          return LaserRanging
        default:
          return {}
      }
    case 'CapacitiveSensor':
      switch (series) {
        case 'StandardFunctionSeries':
          return CapacitanceStandard
        case 'FrequencyEnhancedSeries':
          return CapacitorFrequency
        case 'EnhancedLongRangeSeries':
          return CapacitanceEnhancement
        default:
          return {}
      }
    case 'InductiveSensor':
      switch (series) {
        case 'StandardFunctionSeries':
          return InductanceStandards
        case 'IntrinsicSafetySeries':
          return InductanceEssence
        case 'AnalogOutputSeries':
          return InductorAnalog
        default:
          return {}
      }
    case 'PhotoelectricSensor':
      switch (series) {
        case 'MicroFlatSeries(PSV)':
          return PhotoelectricMicroBias
        case 'MicroSquareSeries(PST/PSJ)':
          return OptoelectronicMicroSquare
        case 'SmallSquareSeries(PSE)':
          return OptoelectronicSmallSquare
        default:
          return {}
      }
    case 'MeasurementSensor':
      switch (series) {
        case 'High-precision laser displacement sensor':
          return LaserRanging
        case 'Laser displacement sensor':
          return LaserRanging
        default:
          return {}
      }
    case 'Конденсаторныйдатчик':
      switch (series) {
        case 'Стандартнаяфункциональнаясерия':
          return CapacitanceStandard
        case 'Серияповышеннойчастоты':
          return CapacitorFrequency
        case 'Серияповышеннойдальности':
          return CapacitanceEnhancement
        default:
          return {}
      }
    case 'Индуктивныйдатчик':
      switch (series) {
        case 'Стандартнаяфункциональнаясерия':
          return InductanceStandards
        case 'Серияпоинтринсическойбезопасности':
          return InductanceEssence
        case 'Серияаналогическоговыхода':
          return InductorAnalog
        default:
          return {}
      }
    case 'Фотоэлектрическийдатчик':
      switch (series) {
        case 'Микроплоскостнаясерия(PSV)':
          return PhotoelectricMicroBias
        case 'Микроквадратнаясерия(PST/PSJ)':
          return OptoelectronicMicroSquare
        case 'Малоквадратнаясерия(PSE)':
          return OptoelectronicSmallSquare
        default:
          return {}
      }
    case 'Измерительныйдатчик':
      switch (series) {
        case 'Высокоточный лазерный датчик перемещения':
          return LaserRanging
        case 'лазерный датчик смещения':
          return LaserRanging
        default:
          return {}
      }
    default:
      return {}
  }
}
